package find;

/**
 * 找一个数组中唯一一个出现奇数次的数
 *
 * @author Liaorun
 */
public class FindOneOld {
    public static void main(String[] args) {
        int[] ints = {2, 1, 1, 3, 4, 3, 4, 2, 1};

        int result = 0;

        for (int i = 0; i < ints.length; i++) {
            result = result ^ ints[i];
        }

        System.out.println(result);
    }
}
